package com.hera.process.config.dao;


import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;
import org.springframework.transaction.annotation.Transactional;

import com.hera.base.dao.repository.BaseRepository;
import com.hera.process.config.domain.Department;

public interface DepartmentDao extends BaseRepository<Department, Long> {
	
	@Modifying
	@Transactional
	@Query("delete from Department o where o.organization.idOrganization = ?")
	void deleteByOrganization(Long idOrganization);

}
